package com.iwhalecloud.bss.kite.cucc.order.dto;

import com.iwhalecloud.bss.kite.dataservice.entity.AcctItemHis;
import com.iwhalecloud.bss.kite.dataservice.entity.CustomerOrder;
import com.iwhalecloud.bss.kite.dataservice.entity.OrderAttr;
import com.iwhalecloud.bss.kite.dataservice.entity.OrderContactInfo;
import com.iwhalecloud.bss.kite.dataservice.entity.OrderHandler;
import com.iwhalecloud.bss.kite.dataservice.entity.OrderItem;
import com.iwhalecloud.bss.kite.dataservice.entity.OrderItemAttr;
import com.iwhalecloud.bss.kite.dataservice.entity.OrderItemRel;
import com.iwhalecloud.bss.kite.dataservice.entity.inst.IInst;
import com.iwhalecloud.bss.kite.dataservice.entity.order.DevStaffInfo;
import com.iwhalecloud.bss.kite.dataservice.entity.order.OrderDeposit;
import com.iwhalecloud.bss.kite.dataservice.entity.order.OrderItemChange;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Objects;

/**
 * 实例&订单入库操作对象
 */
public class OrderOperateDTO implements Serializable {

    private static final long serialVersionUID = 5109828974057147993L;

    /**
     * 新增实例<br>
     * key是tableName
     */
    private Map<String, List<IInst>> insertInstMap;

    /**
     * 更新实例<br>
     * key是tableName
     */
    private Map<String, List<IInst>> updateInstMap;

    /**
     * 更新实例(update不为null的值)<br>
     * key是tableName
     */
    private Map<String, List<IInst>> updateInstMapSelective;

    /**
     * 删除实例<br>
     * key是tableName
     */
    private Map<String, List<IInst>> deleteInstMap;

    /**
     * 过户实例<br>
     * key是tableName
     */
    private Map<String, List<IInst>> transferInstMap;

    /**
     * 新增客户订单
     */
    private List<CustomerOrder> insertCustomerOrders;

    /**
     * 更新客户订单
     */
    private List<CustomerOrder> updateCustomerOrders;

    /**
     * 更新客户订单(update不为null的值)
     */
    private List<CustomerOrder> updateCustomerOrdersSelective;

    /**
     * 删除客户订单
     */
    private List<CustomerOrder> deleteCustomerOrders;

    /**
     * 过户客户订单
     */
    private List<CustomerOrder> transferCustomerOrders;

    /**
     * 新增订单项
     */
    private List<OrderItem> insertOrderItems;

    /**
     * 新增订单项关系
     */
    private List<OrderItemRel> insertOrderItemRels;

    /**
     * 新增客户订单属性
     */
    private List<OrderAttr> insertOrderAttrs;

    /**
     * 更新客户订单属性
     */
    private List<OrderAttr> updateOrderAttrs;

    /**
     * 删除客户订单属性
     */
    private List<OrderAttr> deleteOrderAttrs;

    /**
     * 过户客户订单属性
     */
    private List<OrderAttr> transferOrderAttrs;

    /**
     * 新增订单经办人信息
     */
    private List<OrderHandler> insertOrderHandlers;

    /**
     * 新增订单联系人信息
     */
    private List<OrderContactInfo> insertOrderContactInfos;

    /**
     * 新增订单项属性
     */
    private List<OrderItemAttr> insertOrderItemAttrs;

    /**
     * 新增订单项变更记录
     */
    private List<OrderItemChange> insertOrderItemChanges;

    /**
     * 新增订单项费用
     */
    private List<AcctItemHis> insertAcctItems;

    /**
     * 新增发展人(促销人)信息
     */
    private List<DevStaffInfo> insertDevStaffInfos;

    /**
     * 新增预存款信息
     */
    private List<OrderDeposit> insertOrderDeposits;

    public Map<String, List<IInst>> getInsertInstMap() {
        if (Objects.isNull(insertInstMap)) {
            insertInstMap = new HashMap<>();
        }
        return insertInstMap;
    }

    public void setInsertInstMap(Map<String, List<IInst>> insertInstMap) {
        this.insertInstMap = insertInstMap;
    }

    public Map<String, List<IInst>> getUpdateInstMap() {
        if (Objects.isNull(updateInstMap)) {
            updateInstMap = new HashMap<>();
        }
        return updateInstMap;
    }

    public void setUpdateInstMap(Map<String, List<IInst>> updateInstMap) {
        this.updateInstMap = updateInstMap;
    }

    public Map<String, List<IInst>> getUpdateInstMapSelective() {
        if (Objects.isNull(updateInstMapSelective)) {
            updateInstMapSelective = new HashMap<>();
        }
        return updateInstMapSelective;
    }

    public void setUpdateInstMapSelective(Map<String, List<IInst>> updateInstMapSelective) {
        this.updateInstMapSelective = updateInstMapSelective;
    }

    public Map<String, List<IInst>> getDeleteInstMap() {
        if (Objects.isNull(deleteInstMap)) {
            deleteInstMap = new HashMap<>();
        }
        return deleteInstMap;
    }

    public void setDeleteInstMap(Map<String, List<IInst>> deleteInstMap) {
        this.deleteInstMap = deleteInstMap;
    }

    public Map<String, List<IInst>> getTransferInstMap() {
        if (Objects.isNull(transferInstMap)) {
            transferInstMap = new HashMap<>();
        }
        return transferInstMap;
    }

    public void setTransferInstMap(Map<String, List<IInst>> transferInstMap) {
        this.transferInstMap = transferInstMap;
    }

    public List<CustomerOrder> getInsertCustomerOrders() {
        if (Objects.isNull(insertCustomerOrders)) {
            insertCustomerOrders = new ArrayList<>();
        }
        return insertCustomerOrders;
    }

    public void setInsertCustomerOrders(List<CustomerOrder> insertCustomerOrders) {
        this.insertCustomerOrders = insertCustomerOrders;
    }

    public List<CustomerOrder> getUpdateCustomerOrders() {
        if (Objects.isNull(updateCustomerOrders)) {
            updateCustomerOrders = new ArrayList<>();
        }
        return updateCustomerOrders;
    }

    public void setUpdateCustomerOrders(List<CustomerOrder> updateCustomerOrders) {
        this.updateCustomerOrders = updateCustomerOrders;
    }

    public List<CustomerOrder> getUpdateCustomerOrdersSelective() {
        if (Objects.isNull(updateCustomerOrdersSelective)) {
            updateCustomerOrdersSelective = new ArrayList<>();
        }
        return updateCustomerOrdersSelective;
    }

    public void setUpdateCustomerOrdersSelective(List<CustomerOrder> updateCustomerOrdersSelective) {
        this.updateCustomerOrdersSelective = updateCustomerOrdersSelective;
    }

    public List<CustomerOrder> getDeleteCustomerOrders() {
        if (Objects.isNull(deleteCustomerOrders)) {
            deleteCustomerOrders = new ArrayList<>();
        }
        return deleteCustomerOrders;
    }

    public void setDeleteCustomerOrders(List<CustomerOrder> deleteCustomerOrders) {
        this.deleteCustomerOrders = deleteCustomerOrders;
    }

    public List<CustomerOrder> getTransferCustomerOrders() {
        if (Objects.isNull(transferCustomerOrders)) {
            transferCustomerOrders = new ArrayList<>();
        }
        return transferCustomerOrders;
    }

    public void setTransferCustomerOrders(List<CustomerOrder> transferCustomerOrders) {
        this.transferCustomerOrders = transferCustomerOrders;
    }

    public List<OrderItem> getInsertOrderItems() {
        if (Objects.isNull(insertOrderItems)) {
            insertOrderItems = new ArrayList<>();
        }
        return insertOrderItems;
    }

    public void setInsertOrderItems(List<OrderItem> insertOrderItems) {
        this.insertOrderItems = insertOrderItems;
    }

    public List<OrderItemRel> getInsertOrderItemRels() {
        if (Objects.isNull(insertOrderItemRels)) {
            insertOrderItemRels = new ArrayList<>();
        }
        return insertOrderItemRels;
    }

    public void setInsertOrderItemRels(List<OrderItemRel> insertOrderItemRels) {
        this.insertOrderItemRels = insertOrderItemRels;
    }

    public List<OrderAttr> getInsertOrderAttrs() {
        if (Objects.isNull(insertOrderAttrs)) {
            insertOrderAttrs = new ArrayList<>();
        }
        return insertOrderAttrs;
    }

    public void setInsertOrderAttrs(List<OrderAttr> insertOrderAttrs) {
        this.insertOrderAttrs = insertOrderAttrs;
    }

    public List<OrderAttr> getUpdateOrderAttrs() {
        if (Objects.isNull(updateOrderAttrs)) {
            updateOrderAttrs = new ArrayList<>();
        }
        return updateOrderAttrs;
    }

    public void setUpdateOrderAttrs(List<OrderAttr> updateOrderAttrs) {
        this.updateOrderAttrs = updateOrderAttrs;
    }

    public List<OrderAttr> getDeleteOrderAttrs() {
        if (Objects.isNull(deleteOrderAttrs)) {
            deleteOrderAttrs = new ArrayList<>();
        }
        return deleteOrderAttrs;
    }

    public void setDeleteOrderAttrs(List<OrderAttr> deleteOrderAttrs) {
        this.deleteOrderAttrs = deleteOrderAttrs;
    }

    public List<OrderAttr> getTransferOrderAttrs() {
        if (Objects.isNull(transferOrderAttrs)) {
            transferOrderAttrs = new ArrayList<>();
        }
        return transferOrderAttrs;
    }

    public void setTransferOrderAttrs(List<OrderAttr> transferOrderAttrs) {
        this.transferOrderAttrs = transferOrderAttrs;
    }

    public List<OrderHandler> getInsertOrderHandlers() {
        if (Objects.isNull(insertOrderHandlers)) {
            insertOrderHandlers = new ArrayList<>();
        }
        return insertOrderHandlers;
    }

    public void setInsertOrderHandlers(List<OrderHandler> insertOrderHandlers) {
        this.insertOrderHandlers = insertOrderHandlers;
    }

    public List<OrderContactInfo> getInsertOrderContactInfos() {
        if (Objects.isNull(insertOrderContactInfos)) {
            insertOrderContactInfos = new ArrayList<>();
        }
        return insertOrderContactInfos;
    }

    public void setInsertOrderContactInfos(List<OrderContactInfo> insertOrderContactInfos) {
        this.insertOrderContactInfos = insertOrderContactInfos;
    }

    public List<OrderItemAttr> getInsertOrderItemAttrs() {
        if (Objects.isNull(insertOrderItemAttrs)) {
            insertOrderItemAttrs = new ArrayList<>();
        }
        return insertOrderItemAttrs;
    }

    public void setInsertOrderItemAttrs(List<OrderItemAttr> insertOrderItemAttrs) {
        this.insertOrderItemAttrs = insertOrderItemAttrs;
    }

    public List<OrderItemChange> getInsertOrderItemChanges() {
        if (Objects.isNull(insertOrderItemChanges)) {
            insertOrderItemChanges = new ArrayList<>();
        }
        return insertOrderItemChanges;
    }

    public void setInsertOrderItemChanges(List<OrderItemChange> insertOrderItemChanges) {
        this.insertOrderItemChanges = insertOrderItemChanges;
    }

    public List<AcctItemHis> getInsertAcctItems() {
        if (Objects.isNull(insertAcctItems)) {
            insertAcctItems = new ArrayList<>();
        }
        return insertAcctItems;
    }

    public void setInsertAcctItems(List<AcctItemHis> insertAcctItems) {
        this.insertAcctItems = insertAcctItems;
    }

    public List<DevStaffInfo> getInsertDevStaffInfos() {
        if (Objects.isNull(insertDevStaffInfos)) {
            insertDevStaffInfos = new ArrayList<>();
        }
        return insertDevStaffInfos;
    }

    public void setInsertDevStaffInfos(List<DevStaffInfo> insertDevStaffInfos) {
        this.insertDevStaffInfos = insertDevStaffInfos;
    }

    public List<OrderDeposit> getInsertOrderDeposits() {
        if (Objects.isNull(insertOrderDeposits)) {
            insertOrderDeposits = new ArrayList<>();
        }
        return insertOrderDeposits;
    }

    public void setInsertOrderDeposits(List<OrderDeposit> insertOrderDeposits) {
        this.insertOrderDeposits = insertOrderDeposits;
    }
}
